import { instance } from "../../request";

export const newsPageGetService = (pageNum,PageSize,query)=>{
    return instance({
        method:"get",
        url:"/bsNews/page",
        params:{
            pageNum,
            PageSize,
            ...query
        }
    })
}

export const newGetByIdService = (id)=>{
    return instance({
        method:"get",
        url:`/bsNews/${id}`
    })
}

export const newUpdateService = (bsNew)=>{
    return instance({
        method:"put",
        url:`/bsNews`,
        data:bsNew
    })
}

export const newInsertService = (bsNew)=>{
    return instance({
        method:"post",
        url:`/bsNews`,
        data:bsNew
    })
}